<h1>Add URL</h1>
<form action="" method="post" enctype="multipart/form-data">
	<div class="form-field">
		<label>Domain name:</label>
		<select name="domain_name">
			<option value="">{#RewriteHost#} (default)</option>
			{if #MultiDomainSupport#}
				{foreach $domains as $domain}
					<option value="{$domain.id}"{if $domain_name == $domain.id} selected="selected"{/if}>{$domain.domain}</option>
				{/foreach}
			{/if}
		</select>
	</div>
	<div class="form-field">
		<label>URL set container:</label>
		<select name="url_set_container">
			<option value="">None</option>
			{foreach $url_sets as $url_set}
				<option value="{$url_set.id}"{if $url_set_container == $url_set.id} selected="selected"{/if}>{$url_set.group_name}</option>
			{/foreach}
		</select><br /><br />
	</div>
	<div class="form-field">
		<label><input type="radio" name="entry" value="single" class="no-border" {if !$entry || $entry == 'single'}checked="checked" {/if}/> Single entry:</label>
		<div class="float">
			<div class="sub-form-field">
				<label>Long URL to make tiny:</label>
				<input type="text" name="longurl" value="{$longurl|escape}" onfocus="this.form.entry[0].checked = 'true';" />
			</div>
			<div class="sub-form-field">
				<label>Custom keyword:</label>
				<input type="text" name="keyword" value="{$keyword|escape}" onfocus="this.form.entry[0].checked = 'true';" /><br />(optional)
			</div>
		</div>
		<div class="clear"></div>
	</div>
	<div class="form-field">
		<label><input type="radio" name="entry" value="multiple" class="no-border" {if $entry == 'multiple'}checked="checked" {/if}/> Multiple entries:</label>
		<div class="float">
			<p>List of long URLs to make tiny:</p>
			<textarea name="listurl" rows="7" cols="40" wrap="off" onfocus="this.form.entry[1].checked = 'true';">{$listurl|escape}</textarea>
			<p>({$smarty.const.MAX_LINES_PERMITTED} lines maximum)</p>
		</div>
		<div class="clear"></div>
	</div>
	<div class="form-field">
		<label><input type="radio" name="entry" value="upload" class="no-border" {if $entry == 'upload'}checked="checked" {/if}/> Upload entry:</label>
		<div class="float">
			<input type="file" name="uploadurl" value="{$uploadurl}" onfocus="this.form.entry[2].checked = 'true';" />
			<p>({$smarty.const.MAX_LINES_PERMITTED} lines maximum)</p>
		</div>
		<div class="clear"></div>
	</div>
	<div class="form-field">
		<label>URL options:</label>
		<div class="float">
			Password protection: <input type="text" name="password" value="{$password|escape}" /><br />
			<input type="checkbox" name="cloak" value="1" class="no-border" {if $cloak}checked="checked" {/if}/> Cloak using a frame<br />
			<span class="cb-indent">Title: <input type="text" name="title" value="{$title|escape}" /></span><br />
			Maximum number of hits: <input type="text" name="maxhits" value="{$maxhits|escape}" /><br />
			Expiration date: <input type="text" name="expiration" value="{$expiration|escape}" readonly="readonly" /> <img class="calendar-button" src="../images/calendar.gif" alt="Pick" title="Pick" onclick="displayDatePicker('expiration', false, 'ymd', '-');" /> <img class="empty-button" src="../images/delete.gif" alt="Empty" title="Empty" onclick="document.forms[0].expiration.value = '';" /><br />
			<input type="checkbox" name="disabled" value="1" class="no-border" {if $disabled == "1"}checked="checked" {/if}/> Disable temporarily
		</div>
		<div class="clear"></div>
	</div>
	<div class="form-field">
		<label>&nbsp;</label>
		<input type="submit" name="add_button" value="Create" />
	</div>
</form>